import 'package:flutter/material.dart';
import 'package:flutter_screenutil/flutter_screenutil.dart';

///标签lable
class LableItemWidget extends StatelessWidget{
  @override
  Widget build(BuildContext context) {
    // TODO: implement build
    return Container(
      height: ScreenUtil().setHeight(50.0),
      child: ListView.builder(
        itemBuilder: (context, index) {
          return lableItem();
        },
        itemCount: 5,
        shrinkWrap: true,
        scrollDirection: Axis.horizontal,
      ),
    );
  }

  Widget lableItem() {
    return Container(
      padding: EdgeInsets.only(left: 3.0, right: 3.0),
      alignment: Alignment.center,
      margin: EdgeInsets.all(3.0),
      decoration: BoxDecoration(
          borderRadius: BorderRadius.all(Radius.circular(3.0)),
          color: Colors.orange[50]),
      child: Text(
        '看兵马俑群',
        style: TextStyle(
            color: Colors.orange[400], fontSize: ScreenUtil().setSp(19.0)),
      ),
    );
  }

}